﻿using System;

namespace SimbaRGVMonitor.Common.Net
{
    [Serializable]
    public sealed class MonitorTcpClientDataReceivedEventArgs : MonitorTcpClientEventArgs
    {
        internal MonitorTcpClientDataReceivedEventArgs(MonitorTcpClient tcpClient, DateTime receiveTime, byte[] receiveBytes)
            : base(tcpClient)
        {
            this.receiveTime = receiveTime;
            this.receiveBytes = receiveBytes;
        }

        //====================================================================================================
        //以上是类型构造函数
        //----------------------------------------------------------------------------------------------------
        //以下是类型字段
        //====================================================================================================

        private readonly byte[] receiveBytes;
        private readonly DateTime receiveTime;
        
        //====================================================================================================
        //以上是类型字段
        //----------------------------------------------------------------------------------------------------
        //以下是类型属性
        //====================================================================================================

        public byte[] ReceiveBytes
        {
            get { return receiveBytes; }
        }

        public DateTime ReceiveTime
        {
            get { return receiveTime; }
        }
    }
}
